import request from "@/utils/request";

// 查询品牌分类关联列表
export function listRelation(query) {
  return request({
    url: "/product/categoryrelation/list",
    method: "get",
    params: query,
  });
}

// 查询品牌分类关联详细
export function getRelation(id) {
  return request({
    url: "/product/categoryrelation/" + id,
    method: "get",
  });
}

// 新增品牌分类关联
export function addRelation(data) {
  return request({
    url: "/product/categoryrelation",
    method: "post",
    data: data,
  });
}

// 修改品牌分类关联
export function updateRelation(data) {
  return request({
    url: "/product/categoryrelation",
    method: "put",
    data: data,
  });
}

// 删除品牌分类关联
export function delRelation(id) {
  return request({
    url: "/product/categoryrelation/" + id,
    method: "delete",
  });
}
